'''
Created on Dec 8, 2012

@author: bbg
'''
import unittest
from service.public.login_service import LoginService
from webob import Request, Response


class Test(unittest.TestCase):


    def setUp(self):
        pass


    def tearDown(self):
        pass


    def testWebLogin(self):
        params = {
                  'company_id':20001,
                  'pwd':888,
                  'type':1,
                  'username':'wugang',
                  'sign':'1369f15ea7733f8af5538d2427f062db'
                  }
        req = Request.blank(path='/poscloud/v1/company/login', POST =  params)
        res = Response()
        
        LoginService.process(req, res)
        print res.text
        
        


if __name__ == "__main__":
    #import sys;sys.argv = ['', 'Test.testName']
    unittest.main()